home *** CD-ROM | disk | FTP | other *** search
/ Pascal Super Library / Pascal Super Library (CW International)(1997).bin / SHELLS / SZ2 / ADEMO8.DEF < prev    next >
Text File  |  1992-08-31  |  3KB  |  74 lines

  1. .TUTORIAL - The [ STATUS ] Keyword
  2.  
  3. This editor uses only the StatusLine.
  4.  
  5. This is done with the [ STATUS ] keyword.  The syntax is similar to
  6. the [ SUBMENU ] keyword, except that there are no help context
  7. symbols.
  8.  
  9. Also, the StatusLine can be used for "invisible" key-to-command
  10. mapping.  In this example, note that "kbEsc" is mapped to "cmClose",
  11. although this does NOT appear on the StatusLine.
  12.  
  13.  
  14. 'Til now, you'll note that we haven't done anything with StatusLines,
  15. yet they were there anyway.  By default, SHAZAM adds StatusLine
  16. contexts to cover common context ranges.
  17.  
  18. One reason for this is obvious:  When a hint is displayed, you want
  19. most of the StatusLine to go away so the user can see the hint!
  20.  
  21.                            COMMON CONTEXTS
  22.  
  23.            0,0 - hcNoContext
  24.            1,1 - hcDragging
  25.          2,999 - RESERVED by Turbo Vision
  26.       HelpMode - assigned in *.TXT; used for help window
  27.     1000,$FFFF - program contexts
  28.  
  29.                          INVISIBLE KEY MAPS
  30.  
  31. To each of the above, and to any StatusLines you define, the standard
  32. key maps (found in APP.PAS under InitStatusLine) are added.
  33.  
  34. You can control all of the above using the "/s..." switches.  See the
  35. SETUP|Code dialog or the KEYWORD documentation for more detail.
  36.  
  37.  
  38. NOTE
  39. ----
  40. This is the same as ADEMO6, except that the interface is based on the
  41. StatusLine instead of the MenuBar.  So we re-use the custom
  42. components with the [ APPLICATION ] keyword.
  43.  
  44. (If you wanted to make it independent of ADEMO6, just copy the *.INC,
  45. *.VIR and *.EVT files and delete the line with [ APPLICATION ] on it.)
  46.  
  47. @PA - - - - - - - - - - - - - - - - - - - - - - - - - - - -
  48.  
  49. [ APPLICATION ] ademo6
  50.  
  51. [ UNIT ]
  52. General /r                                       @@ Use & register
  53.  
  54. [ DIALOG ]
  55. replace find                                    @@ *.DLG files
  56.  
  57. [ STATUS ]
  58. ctrl-o open
  59. ctrl-s save
  60. ctrl-r replace
  61. ctrl-f find
  62. ctrl-x quit
  63.               kbEsc     cmClose                  @@ invisible!
  64.  
  65. [ HINT ]
  66. OK                           ;;accept the settings in this dialog box
  67. Cancel                       ;;close the dialog box without making any changes
  68. SearchText                   ;;Text to look for
  69. ReplaceText                  ;;Text to use for replace
  70. SearchType1                  ;;whether to consider case during search
  71. SearchType2                  ;;whether to consider partial matches
  72. SearchType3                  ;;whether to prompt before replacing
  73. SearchType4                  ;;whether to scan entire file
  74.